using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Setting
{

    #region Layer

    public static readonly int PlayerLayer = 1 << LayerMask.NameToLayer("Player");
    public static readonly int EnemyLayer = 1 << LayerMask.NameToLayer("Enemy");

    #endregion
    
    #region Common State Machine Setting
    public const string idle = "Idle";
    public const string move = "Move";
    public const string air = "Air";
    public const string ground = "Ground";
    public const string dead = "Dead";
    #endregion
    
    #region Player State Machine Setting
    public const string wallSlide = "WallSlide";
    public const string wallJump = "WallJump";
    public const  string primaryAttack = "PrimaryAttack";
    public const string dash = "Dash";
    public const string jump = "Jump";
    public const string counter = "Counter";
    public const string swordAim = "SwordAim";
    public const string swordCatch = "SwordCatch";
    public const string backHole = "BackHole";
    #endregion

    #region Enemy State Machine Setting
    public  const string battle = "Battle";
    public  const string attack = "Attack";
    public  const string stun = "Stun";
    #endregion
    
    #region Animation Setting
    public  const string Yvelocity = "Yvelocity";
    
    public const string AnimatorIdle = "Idle";
    public const string AnimatorMove = "Move";
    public const string AnimatorDash = "Dash";
    public const string AnimatorJump = "Jump";
    public const string AnimatorWallSlide = "WallSlide";
    public  const string AnimatorAttack = "Attack";
    public const string AnimatorComboCounter = "ComboCounter";
    public const string AnimatorStun = "Stun";
    public const string AnimatorCounter = "Counter";
    public const string AnimatorSuccessfulCounter  = "SuccessfulCounter";
    public const string AnimatorSwordAim = "SwordAim";
    public const string AnimatorSwordCatch = "SwordCatch";
    public const string AnimatorDead = "Dead";
    #endregion

    #region Player Setting
    public const  float health = 10f;
    public  const float speed = 7f;
    public const float jumpForce = 15f;
    public  const float comboDuration = 1.5f;//连击持续时间
    public const float comboCanMoveTime = 0.12f;//攻击开始0到0.12秒后允许移动
    public const float attackRadius = 0.9f;//攻击检测半径
    public const float counterDuration = 0.2f;//反击架势持续时间
    
    public const float attackDamage = 1f;//基础伤害
    public const float defense = 10f;//护甲值
    public const float criRate = 1f;//暴击率
    public const float criDamage = 2f;//暴击伤害
    public const float dogeRate = 0.1f;//闪避率

    public const float magicResistance = 0;//魔法抗性
    public const float fireDamge = 0;//火焰伤害
    public const float iceDamge = 0;//冰伤害  
    public const float electricDamge = 0;//电伤害
    #endregion

    #region GroundCheck
    public  const float groundCheckRadius = 0.4f;
    public  const float wallCheckLine = 0.3f;
    #endregion

    #region Enmey Config Id Setting
    public const int Skeleton = 1;
    #endregion
    
    #region Skill Name
    //冲刺技能组
    public const string SkillDash = "skill_dash";
    public const string SkillCloneDash = "skill_clone_dash";
    public const  string SkillCloneAttack = "skill_clone_attack";
    //剑技能组
    public  const string SkillThrowSword = "skill_throw_sword";
    public const string SkillBounceSword = "skill_bounce_sword";
    public const string SkillPierceSword = "skill_pierce_sword";
    public  const string SkillRotateSword = "skill_rotate_sword";
    //黑洞技能组
    public const string SkillBlackHole = "skill_black_hole";
    public const string SkillWhiteAttack = "skill_white_hole";
    //水晶技能组
    public const string SkillNormalCrystal = "skill_normal_crystal";
    public const string SkillExplosiveCrystal = "skill_explosive_crystal";
    public const string SkillCloneCrystal = "skill_clone_crystal";
    public const string SkillNbombCrystal = "skill_nbomb_crystal";
    //反击
    public const string SkillCloneCounter = "skill_clone_counter";
    #endregion

    #region  cur Sword  Skill 当前装备的剑技能 临时变量
    public const string curDashSkill = "skill_clone_attack";
    public const  string curSwordSkill = "skill_rotate_sword";
    public const string curHoleSkill = "skill_white_hole";
    public const string curCrystalSkill = "skill_nbomb_crystal";
    public const string curCounterSkill = "skill_clone_counter";
    #endregion

    #region 异常持续时间
    public const float  burningTime = 3f;
    //燃烧间隔
    public const float  burningDely = 1f;
    public const float  frozenTime = 3f;
    public const float  easyDamageTime = 5f;
    #endregion

    #region flyTextColor
    //Fire Color
    public static readonly Color fireColor = new Color(0.93f, 0.25f, 0.3f);
    public static readonly Color iceColor = new Color(0.2f, 0.42f, 0.61f);
    public static readonly Color electricColor = new Color(0.99f, 0.83f, 0.22f);
    public static readonly Color critColor = new Color(0.81f, 0.47f, 0f);
    

    #endregion
}
